cmake_minimum_required(VERSION 3.25)
project(aass3)

set(CMAKE_CXX_STANDARD 20)

add_executable(problem1 p1.cpp)
add_executable(problem1plus p1plus.cpp)
add_executable(problem2 p2.cpp)
add_executable(problem3 p3.cpp)
add_executable(problem3brute p3brute.cpp)
add_executable(problem4 p4.cpp)
add_executable(problem4brute p4brute.cpp)
add_executable(problem5 p5.cpp)
add_executable(problem6 p6.cpp)

add_executable(solution1 submit/solution1.cpp)
add_executable(solution1plus submit/solution1plus.cpp)
add_executable(solution2 submit/solution2.cpp)
add_executable(solution3 submit/solution3.cpp)
add_executable(solution4 submit/solution4.cpp)
add_executable(solution5 submit/solution5.cpp)
add_executable(solution6 submit/solution6.cpp)

add_executable(generate1 submit/generate1.cpp)
add_executable(generate2 submit/generate2.cpp)
add_executable(generate3 submit/generate3.cpp)
add_executable(generate4 submit/generate4.cpp)
add_executable(generate5 submit/generate5.cpp)
add_executable(generate6 submit/generate6.cpp)

add_executable(test1 misc/test1.cpp)

# for Gnome Builder and KDevelop to work, following lines are required
#################################################
install(TARGETS problem1
        RUNTIME DESTINATION bin
        COMPONENT problem1)

install(TARGETS problem1plus
        RUNTIME DESTINATION bin
        COMPONENT problem1plus)

install(TARGETS problem2
		RUNTIME DESTINATION bin
		COMPONENT problem2)

install(TARGETS problem3
		RUNTIME DESTINATION bin
		COMPONENT problem3)

install(TARGETS problem3brute
		RUNTIME DESTINATION bin
		COMPONENT problem3brute)

install(TARGETS problem4
		RUNTIME DESTINATION bin
		COMPONENT problem4)

install(TARGETS problem4brute
		RUNTIME DESTINATION bin
		COMPONENT problem4brute)

install(TARGETS problem5
		RUNTIME DESTINATION bin
		COMPONENT problem5)

install(TARGETS problem6
		RUNTIME DESTINATION bin
		COMPONENT problem6)

##################################################
install(TARGETS solution1
        RUNTIME DESTINATION bin
        COMPONENT solution1)

install(TARGETS solution1plus
        RUNTIME DESTINATION bin
        COMPONENT solution1plus)

install(TARGETS solution2
		RUNTIME DESTINATION bin
		COMPONENT solution2)

install(TARGETS solution3
		RUNTIME DESTINATION bin
		COMPONENT solution3)

install(TARGETS solution4
		RUNTIME DESTINATION bin
		COMPONENT solution4)

install(TARGETS solution5
		RUNTIME DESTINATION bin
		COMPONENT solution5)

install(TARGETS solution6
		RUNTIME DESTINATION bin
		COMPONENT solution6)

##################################################
install(TARGETS generate1
        RUNTIME DESTINATION bin
        COMPONENT generate1)

install(TARGETS generate2
		RUNTIME DESTINATION bin
		COMPONENT generate2)

install(TARGETS generate3
		RUNTIME DESTINATION bin
		COMPONENT generate3)

install(TARGETS generate4
		RUNTIME DESTINATION bin
		COMPONENT generate4)

install(TARGETS generate5
		RUNTIME DESTINATION bin
		COMPONENT generate5)

install(TARGETS generate6
		RUNTIME DESTINATION bin
		COMPONENT generate6)

##################################################
install (TARGETS test1
		RUNTIME DESTINATION bin
		COMPONENT test1)
